home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2007 September / PCWSEP07.iso / Software / Linux / Linux Mint 3.0 Light / LinuxMint-3.0-Light.iso / casper / filesystem.squashfs / var / lib / dpkg / info / gnome-app-install.postrm < prev    next >
Encoding:
Text File  |  2007-04-13  |  1.2 KB  |  41 lines

  1. #!/bin/sh
  2. # postrm script for gnome-app-install
  3.  
  4. set -e
  5.  
  6. if [ "$1" = "purge" ]; then
  7.     # remove the cached application data
  8.     rm -f /var/cache/app-install/*
  9. fi
  10.  
  11.  
  12. # Automatically added by dh_iconcache
  13. [ -d /usr/share/icons/hicolor ] && touch -m /usr/share/icons/hicolor || true
  14. if [ "$1" = "remove" ] && \
  15.    [ -x "`which gtk-update-icon-cache 2>/dev/null`" ] && \
  16.    [ -f /etc/gtk-2.0/gdk-pixbuf.loaders ]; then
  17.        if [ "`find /usr/share/icons/hicolor -mindepth 1 -maxdepth 1 -type d | wc -l`" -gt 0 ] && \
  18.        [ "`find /usr/share/icons/hicolor -mindepth 1 -maxdepth 1 -type f -name index.theme | wc -l`" -eq 1 ]; then
  19.            # we shouldn't bomb out, if gtk-update-icon-cache failes, 
  20.         # it's not important enough
  21.         gtk-update-icon-cache -q /usr/share/icons/hicolor || true;
  22.     else
  23.         # if the icon theme directory has no subdirs, we can remove the cache
  24.         rm -f /usr/share/icons/hicolor/icon-theme.cache || true;
  25.     fi
  26. fi
  27. # End automatically added section
  28. # Automatically added by dh_gconf
  29. if [ "$1" = purge ]; then
  30.     OLD_DIR=/etc/gconf/schemas
  31.     SCHEMA_FILES="gnome-app-install.schemas "
  32.     if [ -d $OLD_DIR ]; then
  33.         for SCHEMA in $SCHEMA_FILES; do
  34.             rm -f $OLD_DIR/$SCHEMA
  35.         done
  36.         rmdir -p --ignore-fail-on-non-empty $OLD_DIR
  37.     fi
  38. fi
  39. # End automatically added section
  40.  
  41.